Calculated (Calculation Based on Other Columns)
A Calculated column type
does not allow the user to enter data in it; it is used only to show
data based on a calculation of other columns. For example, if you want
a Full Name column that displays information automatically based on the
First Name and Last Name columns, you can create a Calculated column
that concatenates the values in those two columns.
As another example, say that
you have a list of orders that has a column for the number of products
ordered and another column for the price for a single product. The
Calculated column can display the total revenue for the order by
multiplying the numbers in the two columns.
The configuration options
for this column type include a special formula builder control that
enables you to specify the calculation required for the column, as
shown in Figure 26.
Formula
In the Formula text box, you can define the calculation that will be performed (refer to Figure 7.39).
You can select the columns on which you want to perform a calculation
from the list on the right and click Add to Formula to add a reference
to that column in the formula.
For example, to
concatenate two text columns, add the two columns from the list and use
the ampersand (&) character to connect them. You can also add a
piece of text in quotation marks. The value is automatically displayed
everywhere, including in list views and views showing the list item’s
or file’s details.
For a complete list of formulas that you can use, see http://tinyurl.com/SPcalculated2010.
The Data Type
The second option you
need to configure for the Calculated column type is the data type that
will be used for the calculation. Select the appropriate data type that
matches the data type of the columns for which you are performing an
operation. It is possible to perform an operation on columns of
different types. For example, you can multiply the value in a Number
column by the value in a Currency column, but you must decide how the
result of the operation will be displayed—either as a number or as
currency.
Rating Scale
The Rating Scale column
type is available only in surveys. You use it when you want the user to
rate several items in a Likert scale control. It’s like asking many
questions in one column, where the answer for each question is a
number. These questions are referred to as the sub-questions of the
column.
For example, you might want to
gather input on user satisfaction on several aspects of a service, or
you might want to know how strongly users agree with certain statements
about different aspects of a book (see Figure 27).
The Rating Scale column
type is useful in surveys where you want to assess how users feel about
multiple subjects. It gives the user an interface for quickly and
easily answering several questions. You can configure this column to
specify what questions will be included, what ratings the user can
choose, and what the values mean. Figure 28 shows the configuration page for this column type.